package com.huawei.tree.binary_tree_array;

//测试顺序二叉树遍历
//创建一个二叉树
//                                      1:亚索
//                  2：诺手                                  3：盲僧
//         4：瑞文            5：腕豪               6：剑圣               7：螳螂
//    8:狗头    9：武器   10：凯南   11：纳尔     12：豹女  13：千珏    14：凯影    15：小丑
public class BinaryTreeArrayTest {
    public static void main(String[] args) {
        String[] array = {"亚索","诺手","盲僧","瑞文","腕豪","剑圣","螳螂","狗头","武器","凯南","纳尔","豹女","千珏","凯影","小丑"};
        BinaryTreeArray binaryTreeArray = new BinaryTreeArray(array);
        System.out.println("顺序存储前序遍历：");
        binaryTreeArray.preOrder();
        System.out.println();
        System.out.println("顺序存储中序遍历：");
        binaryTreeArray.midOrder();
        System.out.println();
        System.out.println("顺序存储后序遍历：");
        binaryTreeArray.afterOrder();
    }
}
